Represents a phone number consisting of a key for the access and a phone number. This class can be used
together with the class LSANamedList and implemets the AnyItem interface.
- Version:
-
1.2.3, 27.JUL.2000
- History:
| RGR | 27.JUL.2000 | Property CountriesWithoutAreaCode added
|
Public Property Set Key AsString
Sets the description of the phone number; e.g. "Private" for your home phone number
- Errors:
Public Property Get Key AsString
Public Property Set CountryCode AsString
Sets the country code of a phone number. Leading "+" or zeros will be trimmed away.
Public Property Get CountryCode AsString
Public Property Set AreaCode AsString
Sets the country code of a phone number. Leading "+" or zeros will be trimmed away.
Public Property Get AreaCode AsString
Public Property Set PhoneNumber AsString
The basic number of a phone number; leading zeros will be removed.
Public Property Get PhoneNumber AsString
Public Property Set Extension AsString
The basic number of a phone number; leading zeros will be removed.
Public Property Get Extension AsString
Public Property Set CountriesWithoutAreaCode AsVariant
List of country codes which doesn't have to be followed by an area code in validation
Public Property Get CountriesWithoutAreaCode AsVariant
Public Property Set Delimiter AsString
When the object is imploded to a serial data string this character will be used as seperator.
If the programmer doesn't set a delimiter a default value will be delivered by the class.
Public Property Get Delimiter AsString
Public Property Set NotAllowedChars AsVariant
These characters are not allowed to be use in the key property
Public Property Get NotAllowedChars AsVariant
Public Property Set DisplayFormat AsString
The display format is a rule for formatting the object data
when the property 'Formatted' is used. This is a string based on the formula language
of the VExpand command to format e-mail addresses.The values of the constants PHI_DEFAULT_KEY_NAME,
PHI_DEFAULT_AREA_CODE_NAME, PHI_DEFAULT_COUNTRY_CODE_NAME, DefaultPhoneNumber and DefaultExtension have
to be used to define the format.
Public Property Get DisplayFormat AsString
Public Property Get Formatted AsString
Formats the object's data in a user defined way
New
Public Sub New(NewKey As String,NewCountryCode As String,NewAreaCode As String,NewPhoneNumber As String,NewExtension As String)
This is the constructor of the object. It will set
the properties Key, CountryCode, AreaCode, PhoneNumber
and Extension with the parameter values. Default values for
the properties Delimiter, NotAllowedChars and DisplayFormat are set.
- Parameters:
| NewKey | String | Key to acces this phone number in a list
|
| NewCountryCode | String | country code of the phone number
|
| NewAreaCode | String | area code of the phone number
|
| NewPhoneNumber | String | number
|
| NewExtension | String | extension of the phone number
|
Delete
Public Sub Delete
implode
Public Function implode As String
This method writes the data of the object to a serialized data string.
The string is of the form (Me.Delimiter = "~"):
~~~~~~~.
- Returns:
| String | serial data string representing the object
|
explode
Public Sub explode(SerializedObj As String)
Transforms a string build by the implode method in its components and sets the attribute of the object.
Old values are reseted to the new values.
- Parameters:
| serializedObj | String | String of the format as delivered by the implode method
|
- Errors:
| ErrDataDoesntCorrespondToObject | |
validate
Public Sub validate
The "Key" and "Phone number" or "Extension" property needn't to be empty.
If there is an country code there needs to be area code, too.
- Errors:
| ErrPhoneTypeEmpty | |
| ErrAreaCodeEmpty | |
| ErrLineCodeEmpty | |
clear
Public Sub clear
Clears the values of the phone item object.
After the usage of clear the method IsEmptyInstance will deliver true as return value.
isEmptyInstance
Public Function isEmptyInstance As Integer
The method checks if all attributes are empty strings.
- Returns:
| Boolean | true, if all attribute are empty strings
|
compareTo
Public Function compareTo(CompItem As LSAPhoneItem) As Integer
This method compares the properties Key, AreaCode
CountryCode, PhoneNumber and Extension of the PhoneItem object.
- Returns:
| Boolean | true, if all attribute are equal
|
hasAttributeChanged
Public Function hasAttributeChanged(attrName As String) As Integer
Checks the attribute with the name attrName heen changed
- Parameters:
| attrName | String | the name of the attribute to check
|
- Returns:
| boolean | true, if the attribute has changed
|
hasChanged
Public Function hasChanged As Integer
Checks if one of the objects attributes has been changed
| Top | LotusScript Doc |
| © Lotus Professional Services |
| generated on : 05-Apr-01 8:40:00 AM |